/*
Copyright (c) [2019年5月1日] [吴超]
[MBT_Studio] is licensed under Mulan PSL v2.
You can use this software according to the terms and conditions of the Mulan PSL v2.
You may obtain a copy of Mulan PSL v2 at:
		 http://license.coscl.org.cn/MulanPSL2
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
See the Mulan PSL v2 for more details.
*/
#include "相机控制.h"
#include <物体/S_摄像机.h>

static float32	g视点距离 = {};
static vec3		g视点偏移 = {};
static vec3		g眼睛位置 = {};
static vec3		g视点 = {};

static vec3		gX平移方向 = {};
static vec3		gY平移方向 = {};





//S_Sphere f_camera_get视线方向和距离(S_摄像机* camera) {
//	S_Sphere s;
//
//	auto rx = RotationMatrix(M_角度转弧度(camera->m_变换.rotation.x), { 1.0f,0.0f,0.0f });
//	auto ry = RotationMatrix(M_角度转弧度(-camera->m_变换.rotation.y), { 0.0f,1.0f,0.0f });
//	auto sel = ScaleMatrix({ 1.0f, -1.0f, 1.0f });
//
//	s.pos = vec_normalize2(ry * rx * sel * vec3{ 0, 0, 1 });
//	s.radius = fabs(camera->m_视点距离);
//	return s;
//}




//vec3 f_camera_getX平行方向() {
//	//gX平移方向 = 
//	//return vec3();
//	return {};
//}

//vec3 f_camera_get眼睛位置() {
//	return { -g眼睛位置.x, -g眼睛位置.y, -g眼睛位置.z };
//}

//vec3 f_camera_get视点全局位置() {
//	return g视点 + g视点偏移;
//}





